<div id="templates" class="main-content" data-ng-init="ctrl.getAllTemplates()">
    <ng-include src="ctrl.templateUrl"></ng-include>

    <div class="col-md-8 col-md-push-2">
        <div class="widget-modal r">
            <div class="widget-modal-heading">
                All Templates
            </div>
            <div class="widget-modal-body">


                <div class="gap">
                    <input type="search"
                           id="filter"
                           class="form-control text-center"
                           ng-model="ctrl.search"
                           placeholder="Type to find template"/>
                </div>

                <div class="row gap">
                    <div class="col-sm-4 col-sm-push-8 text-center">
                        <div>
                            <div class="create-dashboard-button btn btn-default btn-wide-2x"
                                 ng-click="ctrl.goToManager()">
                                <span class="fa fa-stack fa-lg">
                                    <span class="fa-circle-thin fa-stack-2x"></span>
                                    <span class="fa-plus fa-stack-1x"></span>
                                </span>
                                <br/>
                                Create a new<br/>template
                            </div>
                        </div>
                    </div>
                    <div class="col-sm-8 col-sm-pull-4">
                        <div>
                            <div class="text-2x">All Templates <span class="label label-default"></span></div>

                            <ul class="list-animate list-group text-left">
                                <li class="list-group-item" ng-repeat="myitem in ctrl.templates">
                                    <span class="pull-right">
                                       <a href ng-click="ctrl.deleteTemplate(myitem)">
                                           <span class="fa fa-lg fa-trash text-danger"></span>
                                       </a>
                                    </span>

                                    <a class="btn-block clickable" ng-click="ctrl.viewTemplateDetails(myitem)">
                                        <span class="fa fa-lg left-icon"></span>
                                        {{ myitem.template }}
                                    </a>
                                </li>
                            </ul>
                        </div>


                    </div>
                </div>
            </div>
        </div>
    </div>
</div>